The rapidly growing database of completely sequenced genomes of bacteria, archaea and eukaryotes (approximately 20 genomes available by the end of 1998 and many more in progress) creates both new opportunities and new challenges. In order to take advantage of this information, we developed a system of conserved protein families that include likely orthologous proteins (direct counterparts) from 8 completely sequenced genomes. The process of incorporation of all the remaining completely sequenced genomes is in progress. This system allows nearly automatic functional annotation of more 50% of the proteins encoded in each of the tested bacterial and archaeal genomes, though only about 20% of the eukaryotic proteins fit into these groups. In addition to functional prediction, this approach provides for the systematic delineation of the set of ancient, conserved protein families that are missing in any particular genome. Examination of evolutionary patterns (i.e. representation of different species iand phylogenetic lineages) in the families of orthologs suggests a major role of horizontal gene transfer and lineage specific gene loss in the evolution of prokaryotes. More specifically, comparative analysis of the first available genome of hyperthermophilic bacterium (Aquifex aeolicus) and archaeal genomes indicates massive gene exchange between archaeal and bacterial thermophiles. Comparative genomics has now become a part of any study on the evolution of a particular protein family or a functional system. Frequently examination of the phylogenetic distribution of structural domains and proteins with specific domain architectures provides for the possibility of detailed reconstructions of evolutionary scenarios. Such analyses were performed for the DNA repair systems of bacteria, archaea and eukaryotes and for the eukaryotic programmed cell death systems. Significant roles of horizontal gene transfer and multiple domain rearrangements in the evolution of both systems were demonstrated and a number of new functional predictions were made.